package com.cy.补充.inner.noname;

public class Person {
    public void makeChildren(){
        //Runnable r = new Runnable(){
        //    @Override
        //    public void run() {
        //        while (true) {
        //            System.out.println("哈哈哈");
        //            try {
        //                Thread.sleep(1000);
        //            } catch (InterruptedException e) {
        //                throw new RuntimeException(e);
        //            }
        //        }
        //    }
        //};
        //
        //Thread t = new Thread(r);
        //t.start();

        new Thread(){
            public void run(){
                while (true) {
                    System.out.println("吼吼吼");
                    try {
                        Thread.sleep(1000);
                    } catch (InterruptedException e) {
                        throw new RuntimeException(e);
                    }
                }
            }
        }.start();
    }
}
